package com.taiyi.renaissancemall.Utils;

import com.bumptech.glide.load.engine.DiskCacheStrategy;
import com.bumptech.glide.request.RequestOptions;
import com.taiyi.renaissancemall.R;

public class GlideOptionsManager {
    private static RequestOptions requestOptions;

    public static RequestOptions getInstance() {
        if (requestOptions == null) {
            synchronized (Object.class) {
                if (requestOptions == null) {
                    requestOptions = new RequestOptions();
                    requestOptions.skipMemoryCache(true).diskCacheStrategy(DiskCacheStrategy.RESOURCE).placeholder(R.mipmap.ic_launcher_foreground).dontAnimate();
                }
            }
        }
        return requestOptions;
    }

    private GlideOptionsManager() {

    }
}
